﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Shared/Site.Master" AutoEventWireup="true"
    CodeBehind="KH_TraPhong.aspx.cs" Inherits="Hotel_Admin.KH_TraPhong" %>

<%@ Register Assembly="Hotel.Controls" Namespace="Hotel.Controls" TagPrefix="hotel" %>
<%@ Register Src="us_HelpStatus.ascx" TagName="us_HelpStatus" TagPrefix="uc1" %>
<%@ Register Src="us_HelpStatusOfPhieuDat.ascx" TagName="us_HelpStatusOfPhieuDat"
    TagPrefix="uc2" %>
    <%@ Register Assembly="Microsoft.ReportViewer.WebForms, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
    Namespace="Microsoft.Reporting.WebForms" TagPrefix="rsweb" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <style type="text/css">
        .helper
        {
            float: right;
            padding-right: 20px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <div class="crmcontainer">
        <asp:UpdatePanel runat="server" ID="upInfor" UpdateMode="Conditional">
            <ContentTemplate>
                <table class="crmtable">
                    <tbody>
                        <tr>
                            <td class="crmcell right">
                                CMND
                            </td>
                            <td>
                                <div class="left width-200">
                                    <asp:TextBox ID="txtCMND" runat="server"></asp:TextBox>
                                </div>
                                <div class="left">
                                    <div class="right">
                                        Tên khách hàng</div>
                                </div>
                                <div class="left">
                                    <asp:TextBox runat="server" ID="txtTenKhachHang" />
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td class="crmcell right">
                                Mã số thuế
                            </td>
                            <td>
                                <div class="left width-200">
                                    <asp:TextBox ID="txtMST" runat="server" />
                                </div>
                                <div class="left">
                                    <div class="right">
                                        Địa chỉ</div>
                                </div>
                                <div class="left">
                                    <asp:TextBox runat="server" ID="txtDiaChi" />
                                </div>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                &nbsp;
                            </td>
                            <td>
                                <asp:Button ID="btnFilter" CssClass="btnGui" Text="Lọc" runat="server" OnClick="btnFilter_Click" />
                                <asp:Button ID="btnSave" CssClass="btnGui" Text="Thanh toán" runat="server" OnClick="btnSave_Click" />
                                <asp:Button ID="btnDelete" CssClass="btnGui hidden" Text="Xóa" runat="server" OnClick="btnDelete_Click" />
                                <asp:Button ID="btnHuy" CssClass="btnGui" Text="Hủy" runat="server" OnClick="btnHuy_Click" />
                            </td>
                        </tr>
                        <tr>
                            <td>
                                &nbsp;
                            </td>
                            <td class="helper">
                                <uc2:us_HelpStatusOfPhieuDat ID="us_HelpStatusOfPhieuDat1" runat="server" />
                            </td>
                        </tr>
                    </tbody>
                </table>
            </ContentTemplate>
        </asp:UpdatePanel>
        <asp:UpdatePanel runat="server" ID="upGird" UpdateMode="Conditional">
            <ContentTemplate>
                <hotel:Grid ID="gvList" runat="server" UseCustomPager="true" OnRowCommand="gvList_RowCommand"
                    OnRowDataBound="gvList_RowDataBound">
                    <PagerSettings FirstPageText="phiếu đặt phòng " PageButtonCount="2" />
                    <Columns>
                        <asp:TemplateField HeaderText="Mã phiếu đặt phòng " HeaderStyle-Width="18%">
                            <ItemTemplate>
                                <%# Eval("MaPhieuDat")%>
                            </ItemTemplate>
                            <ItemStyle Font-Bold="True" />
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Tên khách hàng" HeaderStyle-Width="10%">
                            <ItemTemplate>
                                <%# Eval("HoTen") %>
                            </ItemTemplate>
                            <ItemStyle Font-Bold="True" />
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Chứng minh nhân dân" HeaderStyle-Width="10%">
                            <ItemTemplate>
                                <%# Eval("CMND") %>
                            </ItemTemplate>
                            <ItemStyle Font-Bold="True" />
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Ngày đặt" HeaderStyle-Width="15%">
                            <ItemTemplate>
                                <%# Eval("NgayDat") %>
                            </ItemTemplate>
                            <ItemStyle Font-Bold="True" />
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Số phòng" HeaderStyle-Width="15%">
                            <ItemTemplate>
                                <%# Eval("SoLuong") %>
                            </ItemTemplate>
                            <ItemStyle Font-Bold="True" />
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="tùy chọn " HeaderStyle-Width="20%">
                            <ItemTemplate>
                                <asp:LinkButton ID="linkCheckOut" runat="server" CommandArgument='<%# Eval("MaPhieuDat") %>'
                                    CommandName="CheckOut" CssClass="link" Text="Thanh toán"></asp:LinkButton>
                            </ItemTemplate>
                            <ItemStyle Font-Bold="True" />
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Tình trạng " HeaderStyle-Width="10%">
                            <ItemTemplate>
                                <asp:Panel runat="server" ID="status" ForeColor="White" HorizontalAlign="Center"
                                    Height="20px">
                                    <%# Eval("TRANG_THAI_PHIEU_DAT.TenTrangThai") %>
                                </asp:Panel>
                            </ItemTemplate>
                            <ItemStyle Font-Bold="True" />
                        </asp:TemplateField>
                    </Columns>
                </hotel:Grid>
            </ContentTemplate>
        </asp:UpdatePanel>
        <asp:UpdatePanel ID="upnlReport" UpdateMode="Conditional" runat="server">
        <ContentTemplate>
            <div class="crmcontainer" id="divCR" runat="server" visible="false">
                <rsweb:ReportViewer ID="rpViewer" runat="server" Font-Names="Verdana" Font-Size="8pt"
                    InteractiveDeviceInfos="(Collection)" ShowParameterPrompts="true" AsyncRendering="false"
                    WaitMessageFont-Names="Verdana" WaitMessageFont-Size="14pt" Height="1000px" SizeToReportContent="True"
                    Width="800px">
                </rsweb:ReportViewer>
            </div>
        </ContentTemplate>
    </asp:UpdatePanel>
    </div>
</asp:Content>
